Skip to content

Conversation

@chipbarnaby
Copy link
Contributor

Description

64-bit development found an instance of IsSet( record-member) where IsSet( record-member-field-number) was intended.

This PR includes several changes to field status access and testing functions to check that the fn (field number) is an integer. With this, the original offending error was detected along with several more. All have been fixed.

A more robust fix would be to define a type for field number. An issue has been added.

No results changes. No regression test changes. No documentation changes.

src/ancrec.h Outdated
Comment on lines 51 to 62
#if 0
// unsuccessful experiment re general fn type check, 8-2023
template <typename T> struct FLDNUM
{ FLDNUM(T _fn)
{
static_assert(std::is_same<int, T>::value);
fn = _fn;
}
int fn;
};
#endif

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doest this need to be kept? If it has promise, maybe it can be moved to an issue instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree, I will delete.

@chipbarnaby chipbarnaby merged commit 7922708 into main Sep 28, 2023
@chipbarnaby chipbarnaby deleted the status-fcns-typecheck branch September 28, 2023 17:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants